Keir Fraser [Sat, 6 Mar 2010 13:31:03 +0000 (13:31 +0000)]
blktap: provide a variant of __RING_SIZE() that is an integer constant expression
Without this new variant, gcc 4.5 won't compile where this is being
used to specify array sizes. See also c/s 20975.
Signed-off-by: Charles Arnold <carnold@novell.com>
Keir Fraser [Fri, 5 Mar 2010 14:42:25 +0000 (14:42 +0000)]
xend: XenAPI does not support pvSCSI multipath
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Fri, 5 Mar 2010 14:40:19 +0000 (14:40 +0000)]
Fix Makefile targets that generate several files at once
In a few places in the tree the Makefiles have constructs like this:
one_file another_file:
$(COMMAND_WHICH_GENERATES_BOTH_AT_ONCE)
This is wrong, because make will run _two copies_ of the same command
at once. This generally causes races and hard-to-reproduce build
failures.
Notably, `make -j4' at the top level will build stubdom libxc twice
simultaneously!
In this patch we replace the occurrences of this construct with the
correct idiom:
one_file: another_file
another_file:
$(COMMAND_WHICH_GENERATES_BOTH_AT_ONCE)
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Keir Fraser [Fri, 5 Mar 2010 14:39:25 +0000 (14:39 +0000)]
pygrub: Fix grub2 support when config is on a separate /boot partition
Signed-off-by: David Markey <david@dmarkey.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Keir Fraser [Fri, 5 Mar 2010 14:35:44 +0000 (14:35 +0000)]
xl: Fix undefined behaviour when pci not specified in input file
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Keir Fraser [Fri, 5 Mar 2010 14:35:09 +0000 (14:35 +0000)]
Commit output from flex for benefit of prehistoric people
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 5 Mar 2010 14:31:14 +0000 (14:31 +0000)]
vt-d: ensure x2apic is not enabled accidently if no DRHD at all.
Thanks to Jan Beulich for pointing this out.
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Keir Fraser [Fri, 5 Mar 2010 14:30:45 +0000 (14:30 +0000)]
[PV-GRUB DOC] Add details to PV-GRUB documentation
Add a couple of documentation details about PV-GRUB support
- the menu.lst content can be passed as a ramdisk.
- virtual partitions are not supported.
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Keir Fraser [Wed, 3 Mar 2010 17:41:58 +0000 (17:41 +0000)]
x86-64: fix hotplug fault handling for 32-bit domains' M2P range
- handle only when memory hotplug regions were actually found
- fix off-by-one error in fault handler's sanity checking
- use first L4 table entry
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 3 Mar 2010 17:40:48 +0000 (17:40 +0000)]
xentop: tmem: no stats for non-tmem domains
In xentop, don't re-use and print stale data of previous tmem
domain for subsequent non-tmem domain.
Signed-off-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Keir Fraser [Wed, 3 Mar 2010 17:40:22 +0000 (17:40 +0000)]
Fix domain exit actions that contain hyphen
Domain exit actions that contain a hyphen (e.g. rename-restart) were
not being detected properly when xm is configured to use xenapi.
Domain config containing on_crash=3D"rename-restart" results in
xen53:~ # xm new /tmp/domU.config
Using config file "/tmp/domU.config".
Unexpected error: <type 'exceptions.TypeError'>
This patch fixes the raised exception and at the same time
handles the replacement of hyphen with underscore properly.
Signed-off-by: Jim Fehlig <jfehlig@novell.com>
Keir Fraser [Wed, 3 Mar 2010 17:39:22 +0000 (17:39 +0000)]
Replace config file parser for "xl"
This provides a replacement config file parser for "xl" based on bison
and flex.
Benefits:
* proper error reporting with line numbers
* parser can understand nearly all "xm" configuration files directly
(doesn't understand Python code but should do everything else)
* parser also understands the ;-infested "xl" style files
* removes the dependency on libconfig
* better checking for certain kinds of mistakes
* eliminates the strange "massage file and try again" code
This is intended to support all config files currently supported by
"xl" and almost all files supported by "xm". (NB that whether a
feature works depends on the implementation of that feature in
xl/libxl of course.)
This patch also introduces a new library "libxlutil" which is mainly
for the benefit of "xl". Users of libxl do not need to use libxlutil,
but they can do so if they want to parse "xl" files without being
"xl".
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Acked-by: Vincent Hanquez <vincent.hanquez@eu.citrix.com>
Keir Fraser [Tue, 2 Mar 2010 14:05:35 +0000 (14:05 +0000)]
x86: use key handler scratch buffer in dump_irqs()
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Tue, 2 Mar 2010 13:43:48 +0000 (13:43 +0000)]
x86/acpi: Add a missing CR in printk
Signed-off-by: Wei Gang <gang.wei@intel.com>
Keir Fraser [Tue, 2 Mar 2010 13:42:55 +0000 (13:42 +0000)]
Update Xen version to 4.0.0-rc6-pre
Keir Fraser [Mon, 1 Mar 2010 16:50:30 +0000 (16:50 +0000)]
Added tag 4.0.0-rc5 for changeset
92f2ee87e501
Keir Fraser [Mon, 1 Mar 2010 16:50:26 +0000 (16:50 +0000)]
Update Xen version to 4.0.0-rc5
Keir Fraser [Mon, 1 Mar 2010 12:00:11 +0000 (12:00 +0000)]
Revert C/S 20966 "Disable memory mapping warnings when stub domain is used."
It was ealier resolved by C/S 20720 and C/S 20751.
This fix was backported to xen-3.4-testing.
Signed-off-by: Daniel Kiper <dkiper@net-space.pl>
Keir Fraser [Fri, 26 Feb 2010 17:09:50 +0000 (17:09 +0000)]
Revert 20954:
b4041e7bbe1b "paging_domctl: Add missing breaks in switch stmt"
This fixed a fairly innocuous bug (OP_ENABLE/OP_OFF both don't work
properly) but unmasked a much nastier one (turning off shadow mode on
a PV guest crashes the hypervisor).
So, for now, we pick the less of two evils. We don't really much rely
on OP_ENABLE/OP_OFF anyway, as it happens.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 26 Feb 2010 14:06:16 +0000 (14:06 +0000)]
x86: fix number of array elements calculation in
XEN_DOMCTL_getpageframeinfo3 handler
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Fri, 26 Feb 2010 14:05:32 +0000 (14:05 +0000)]
ACPI S3: fix S3 resume fail on system w/ msi capable hpet
Don't re-allocate memory for irq_channel which will cause a BUG_ON in
hpet_msi_write, and make sure hpet_setup_msi_irq() executed during S3
resuming.
Signed-off-by: Wei Gang <gang.wei@intel.com>
Keir Fraser [Fri, 26 Feb 2010 08:13:02 +0000 (08:13 +0000)]
x86_32: Fix build after 20983:
94535cc63835
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 25 Feb 2010 21:03:26 +0000 (21:03 +0000)]
x86 numa: Fix post-boot ACPI SLIT accesses.
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Keir Fraser [Thu, 25 Feb 2010 21:00:54 +0000 (21:00 +0000)]
x86 numa: Fix i386 to not do bogus mfn_to_virt(alloc_boot_pages(...))
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Thu, 25 Feb 2010 20:56:43 +0000 (20:56 +0000)]
ACPI: workaround for S3 fail in two facs tables case
Some legacy BIOS which support ACPI2.0+ may expose two FACS tables via
both FADT->FIRMWARE_CTRL and FADT->X_FIRMWARE_CTRL, but only lookup S3
waking_vector in the first one.
Signed-off-by: Wei Gang <gang.wei@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 25 Feb 2010 11:54:19 +0000 (11:54 +0000)]
VT-d: Fix ia64 build for 20974:
3b475d9ed6b5
This patch fixes the following error on ia64:
iommu.c: In function 'init_vtd_hw':
iommu.c:1831: error: 'nr_ioapics' undeclared (first use in this
function)
Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
Keir Fraser [Thu, 25 Feb 2010 11:52:23 +0000 (11:52 +0000)]
libxc: Pre-zero argument structures for map/unmap_pirq operations.
From: Yunhong Jiang <yunhong.jiang@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 24 Feb 2010 20:27:56 +0000 (20:27 +0000)]
x86: allow SRAT to be used on 32-bit systems with memory beyond 4G
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 24 Feb 2010 20:26:08 +0000 (20:26 +0000)]
x86: Fix build error after c/s 20969:
8cb6e7eff2ba
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 24 Feb 2010 18:48:54 +0000 (18:48 +0000)]
libxc: Fix cpuid() inline asm.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 24 Feb 2010 11:03:56 +0000 (11:03 +0000)]
Provide a variant of __RING_SIZE() that is an integer constant
expression
Without that, gcc 4.5 won't compile (at least) netfront, where this is
being used to specify array sizes.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 24 Feb 2010 10:59:37 +0000 (10:59 +0000)]
vtd: interrupt remapping: be more defensive
1) A buggy BIOS may not report IOAPIC in DRHD. Currently we still try
to enable IR while the IOAPIC RTEs are still in non-remappable format
and the host would hang. The patch detects this case and will not try
to enable IR.
2) Currently HPET's MSI mode doesn't work if IR is enabled because we
have no code to allocate IRTE for it. Luckily this HW configuration is
rather rarely at present, we can just work it around by only using
HPET's IOAPIC mode for now.
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Keir Fraser [Wed, 24 Feb 2010 10:58:03 +0000 (10:58 +0000)]
sched_credit: Reduce is_urgent flag check to a WARN_ON.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 24 Feb 2010 10:57:24 +0000 (10:57 +0000)]
cpuidle: Small fix to urgent_count update logic.
From: Ke Yu <ke.yu@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 24 Feb 2010 10:47:34 +0000 (10:47 +0000)]
[IA64] Support preemption in multicall
After 19946:
91407452cdb6, preemption in multicall may happen while HVM
domains are running. It cause hypervisor's panic on ia64.
This patch implements it in the same way to x86.
Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
Keir Fraser [Wed, 24 Feb 2010 10:46:49 +0000 (10:46 +0000)]
xm: Show usage message of xm commands
The following commands don't show an usage message even if we give
a wrong option to the commands.
- xm block-list
- xm network-list
- xm network2-list
- xm vtpm-list
- xm pci-list
- xm scsi-list
e.g.
# xm block-list --xxx vm1
Error: option --xxx not recognized
This patch shows the usage message of the commands.
e.g.
# xm block-list --xxx vm1
Error: option --xxx not recognized
Usage: xm block-list <Domain> [--long]
List virtual block devices for a domain.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Wed, 24 Feb 2010 10:44:30 +0000 (10:44 +0000)]
x86: Generalise BUGFRAME_dump mechanism to allow polled UART irq to
get proper regs argument.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 24 Feb 2010 09:38:35 +0000 (09:38 +0000)]
xend: notify xenpv device model that console info is ready
Sometimes PV domain with vfb doesn't boot up. /sbin/kudzu is stuck.
After investigation, I've found that the evtchn for console is not
bound at all.
Normal sequence of evtchn initialization in qemu-dm for xenpv is:
1) watch xenstore backpath (/local/domain/0/backend/console/<domid>/0)
2) read console info (/local/domain/<domid>/console/{type, ring-ref,
port..=
})
3) bind the evtchn to the port.
But in some case, xend writes to the backpath before the console info
is prepared, and never write to the backpath again. So the qemu-dm
fails at 2) and never reach to 3).
When this happens, manually xenstore-write command on Domain-0
resumes the guest.
Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
Keir Fraser [Mon, 22 Feb 2010 18:47:22 +0000 (18:47 +0000)]
python: Don't install anything directly under /usr/share
Signed-off-by: Guillaume Rousse <Guillaume.Rousse@inria.fr>
Keir Fraser [Mon, 22 Feb 2010 18:46:09 +0000 (18:46 +0000)]
Disable memory mapping warnings when stub domain is used.
Signed-off-by: Daniel Kiper <dkiper@net-space.pl>
Keir Fraser [Mon, 22 Feb 2010 18:42:50 +0000 (18:42 +0000)]
hvmloader: Replace unportable usage of GNU head with portable awk.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 22 Feb 2010 10:08:10 +0000 (10:08 +0000)]
[IA64] Support grant_table v2 for XENMAPSPACE_grant_table
This patch is ia64 counter part of 20281:
95ea2052b41b.
This fixes the issue that HVM domains with PV-on-HVM drivers panic.
Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
Keir Fraser [Mon, 22 Feb 2010 10:07:27 +0000 (10:07 +0000)]
Fix blktap2 test in xen-hotplug-cleanup
The blktap2 test in xen-hotplug-cleanup was not quite right, causing
orphaned /vm/<uuid>/device node in xenstore. Attempt to reattach the
device failed:
xen53: # xm block-attach 0 file:/tmp/d0 /dev/xvdp r
xen53: # xm block-detach 0 /dev/xvdp
xen53: # xenstore-ls /vm/
00000000-0000-0000-0000-
000000000000/device
vbd =3D ""
51952 =3D ""
frontend =3D "/local/domain/0/device/vbd/51952"
frontend-id =3D "0"
backend-id =3D "0"
backend =3D "/local/domain/0/backend/vbd/0/51952"
xen53: # xm block-attach 0 file:/tmp/d0 /dev/xvdp r
Error: Device /dev/xvdp (51952, vbd) is already connected.
Usage: xm block-attach <Domain> <BackDev> <FrontDev> <Mode>
[BackDomain]
From: Jim Fehlig <jfehlig@novell.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 22 Feb 2010 10:06:21 +0000 (10:06 +0000)]
Fix for fs-backend crash when xend was not started after system boot.
Signed-off-by: Daniel Kiper <dkiper@net-space.pl>
Keir Fraser [Mon, 22 Feb 2010 10:05:40 +0000 (10:05 +0000)]
pv-on-hvm: Fix unplug logic
Add the missing part for the dev_unplug parameter in r20847
Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Keir Fraser [Mon, 22 Feb 2010 10:04:22 +0000 (10:04 +0000)]
hvmloader: fix vgatype detecting issue
When graphics card is assigned to a guest as a secondary VGA,
without gfx_passthru and emulated VGA is the primary VGA,
hvmloader misreads gfx_passthru is specified if VGA device is
found after the emulated VGA.
This patch fix this issue. If emulated VGA is found, hvmloader
preserves it and loads vgabios of the emulated VGA.
Signed-off-by: Noboru Iwamatsu <n_iwamatsu@jp.fujitsu.com>
Keir Fraser [Mon, 22 Feb 2010 10:02:17 +0000 (10:02 +0000)]
tmem: Quieten noisy printk in non-debug build
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 22 Feb 2010 10:00:59 +0000 (10:00 +0000)]
Keir Fraser [Mon, 22 Feb 2010 10:00:24 +0000 (10:00 +0000)]
xm: Fix xm network-list for XenAPI
When I use XenAPI, MAC addresses are not shown by xm network-list.
MAC addresses are shown by this patch.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Mon, 22 Feb 2010 09:58:48 +0000 (09:58 +0000)]
paging: Remove noisy printk
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Keir Fraser [Wed, 17 Feb 2010 15:54:40 +0000 (15:54 +0000)]
tmem: When failing allocs from "midsize alloc zone", try the tmem
pools rather than fail outright.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 17 Feb 2010 12:11:13 +0000 (12:11 +0000)]
paging_domctl: Add missing breaks in switch stmt.
From: Tim Deegan <Tim.Deegan@citrix.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 17 Feb 2010 12:05:45 +0000 (12:05 +0000)]
Mask AMD CPUID masks in software before writing them to the MSRs
Mask AMD CPUID masks in software before writing them to the MSRs.
Setting bits in the CPUID mask MSR that are not set in the unmasked
CPUID response can cause those bits to be set in the masked response.
Avoid that by explicitly masking in software.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Keir Fraser [Wed, 17 Feb 2010 12:04:50 +0000 (12:04 +0000)]
x86/mcheck: do not blindly de-reference dom0 et al
Since machine checks and CMCIs can happen before Dom0 even gets
constructed, the handlers of these events have to avoid de-referencing
respective pointers without checking.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Tue, 16 Feb 2010 18:11:17 +0000 (18:11 +0000)]
Added tag 4.0.0-rc4 for changeset
912295f1b1f3
Keir Fraser [Tue, 16 Feb 2010 18:11:04 +0000 (18:11 +0000)]
Update Xen version to 4.0.0-rc4
Keir Fraser [Tue, 16 Feb 2010 11:55:21 +0000 (11:55 +0000)]
Added tag 4.0.0-rc3 for changeset
7d565d58f498
Keir Fraser [Tue, 16 Feb 2010 11:55:18 +0000 (11:55 +0000)]
Update Xen version to 4.0.0-rc3
Keir Fraser [Tue, 16 Feb 2010 09:28:39 +0000 (09:28 +0000)]
hotplug: ignore xenstore-read error
The failure to read "backend/tap/<domid>/*" in the xenstore is a usual
case since the domain is gone after xenstore-ls command is executed.
The error should be ignored.
Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
Keir Fraser [Tue, 16 Feb 2010 09:27:45 +0000 (09:27 +0000)]
cpuidle: do not enter deep C state if there is urgent VCPU
when VCPU is polling on event channel, it usually has urgent task
running, e.g. spin_lock, in this case, it is better for cpuidle driver
not to enter deep C state.
This patch fix the issue that SLES 11 SP1 domain0 hangs in the box of
large number of CPUs (>= 64 CPUs).
Signed-off-by: Yu Ke <ke.yu@intel.com>
Signed-off-by: Tian Kevin <kevin.tian@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 15 Feb 2010 17:54:04 +0000 (17:54 +0000)]
When tmem is enabled, reserve a fraction of memory
for allocations of 0<order<9 to avoid fragmentation
issues.
Signed-off by: Dan Magenheimer <dan.magenheimer@oracle.com>
Keir Fraser [Mon, 15 Feb 2010 17:49:14 +0000 (17:49 +0000)]
If the 'sched' parameter is unrecognized, choose the first scheduler
Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>
Keir Fraser [Mon, 15 Feb 2010 08:19:07 +0000 (08:19 +0000)]
xend: Remove redundant 'name' from LEGACY_CFG_TYPES and LEGACY_XENSTORE_VM_PARAMS
Two 'name's are defined in LEGACY_CFG_TYPES of XendConfig.py.
LEGACY_XENSTORE_VM_PARAMS also is same.
This patch removes redundant 'name's.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
Keir Fraser [Mon, 15 Feb 2010 08:18:14 +0000 (08:18 +0000)]
xenpaging: Small code style cleanups
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 15 Feb 2010 08:15:08 +0000 (08:15 +0000)]
Fix a small bug about HVM_MAX_VCPUS related array
Currently it doesn't block running, anyway, it better fix the small
bug considering if in the future HVM_MAX_VCPUS will not necessarily be
8x value.
Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>=
Keir Fraser [Mon, 15 Feb 2010 08:14:21 +0000 (08:14 +0000)]
hvmloader: Fix an ACPI asl bug.
Fix an ACPI asl bug by explicitly convert PRS to buffer, otherwise PRS
would be parsed as integer if less than 32/64 bits (according to ACPI
1.0 or 2.0).
Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
Keir Fraser [Mon, 15 Feb 2010 08:13:26 +0000 (08:13 +0000)]
Vcpu hotplug: Move ACPI processor from \_PR to \_SB
Move processor from \_PR to \_SB. ACPI processor can be defined
under \_PR or \_SB. However, recently os like linux 2.6.30/32 support
cpu hotplug better for \_SB processor object.
Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 12 Feb 2010 09:24:18 +0000 (09:24 +0000)]
x86_64: widen bit width usable for struct domain allocation
With it being a PDX (instead of a PFN) that gets stored when a 32-bit
quantity is needed, we should also account for the bits removed during
PFN-to-PDX conversion when doing the allocation.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Fri, 12 Feb 2010 09:23:10 +0000 (09:23 +0000)]
Remus: increase failover timeout from 500ms to 1s
500ms is aggressive enough to trigger split-brain under fairly
ordinary workloads, particularly for HVM. The long-term fix is to
integrate with a real HA monitor like linux HA.
Signed-off-by: Brendan Cully <brendan@cs.ubc.ca>
Keir Fraser [Fri, 12 Feb 2010 09:21:57 +0000 (09:21 +0000)]
keyhandler: Do not serialise keyhandlers; increase scratch array size.
Although serialising keyhandlers is safer, and in particular
protects access to shared heyhandler_scratch[], in debug scenarios it
is probably better to 'have a go' when requested - and assume the user
knows what they are doing.
Meanwhile, increase scratch array size to 1024. That's enough for more
than a dozen lines of 80-column text, and should be plenty in any
practical situation.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 12 Feb 2010 09:16:10 +0000 (09:16 +0000)]
hvmloader: Fix parallel build of ACPI tables.
Make build.c dependency on ssdt_{pm,tpm}.h explicit, else they can be
built in the wrong order.
Also, improve naming of target DSDT structures, and specify -p option
to iasl so that all generated files for a given target have
target-unique names, hence build can proceed safely in parallel.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Fri, 12 Feb 2010 09:14:16 +0000 (09:14 +0000)]
hvmloader: Fix comment style in ssdt_tpm.asl
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 22:42:18 +0000 (22:42 +0000)]
hvmloader: Build a compatibility DSDT with only 15 processor objects.
Deploy this smaller DSDT where possible: this is required to boot
Windows 2000, which only supports up to 15 processors and will blue
screen if it sees more processor objects than that (even inactive
ones).
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 21:49:47 +0000 (21:49 +0000)]
hvmloader: Remove checked-in ready-compiled SSDT_PM and SSDT_TPM.
These can be built at the same time as the DSDT.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 21:21:41 +0000 (21:21 +0000)]
hvmloader: Do not leave compiled DSDT checked in to tree.
It's big and small changes generate huge diffs. People building the
firmware will have to ensure they have iasl installed.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 21:14:12 +0000 (21:14 +0000)]
Dump full vCPU polling mask from 'e' key handler
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 21:08:06 +0000 (21:08 +0000)]
keyhandler: global shared scratch space for temporary strings
Put one static definition in one place and we can make it as big as we
think reasonable.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 19:51:15 +0000 (19:51 +0000)]
VT-d: get rid of duplicated definition
free_pgtable_maddr was implemented the same for x86 and IA64, so it's
not necessary to define it separately for x86 and IA64. This patch
moves free_pgtable_maddr definition to iommu.c to avoid duplicated
definition.
Signed-off-by: Weidong Han <weidong.han@intel.com>
Keir Fraser [Thu, 11 Feb 2010 19:50:42 +0000 (19:50 +0000)]
blktap2: disable presently broken memshr extension
Signed-off-by: Daniel Stodden <daniel.stodden@citrix.com>
Keir Fraser [Thu, 11 Feb 2010 19:50:05 +0000 (19:50 +0000)]
tools/xenpaging: fix bug of Segmentation fault
Segmentation fault occurs in two situations:
1. argc is less than 3
2. xenpaging_init() fault
Signed-off-by: Yu Zhiguo <yuzg@cn.fujitsu.com>
Keir Fraser [Thu, 11 Feb 2010 19:49:31 +0000 (19:49 +0000)]
VT-d: fix coding style in acpi_find_matched_drhd_unit()
Signed-off-by: Weidong Han <weidong.han@intel.com>
Keir Fraser [Thu, 11 Feb 2010 19:48:58 +0000 (19:48 +0000)]
VT-d: ensure zapping ACPI DMAR signature in acpi_parse_dmar
VT-d is owned by Xen hypervisor. Xen zaps ACPI DMAR signature to
prevent dom0 to use VT-d. This patch changes the direct return when
DMAR width is zero, instead zaps ACPI DMAR signature before return.
Signed-off-by: Weidong Han <weidong.han@intel.com>
Keir Fraser [Wed, 10 Feb 2010 13:30:57 +0000 (13:30 +0000)]
tools/xenbaked: fix bug of Segmentation fault
Run xenbaked will cause Segmentation fault, because
the method to get pointers of trace buffer metadata
is wrong. Fix this bug according to xentrace.
Signed-off-by: Yu Zhiguo <yuzg@cn.fujitsu.com>
Keir Fraser [Wed, 10 Feb 2010 13:30:16 +0000 (13:30 +0000)]
libxc: fix bug in xc_tbuf_get_size()
The size in pages of trace buffer should be t_info->tbuf_size
rather than t_info pages.
Signed-off-by: Yu Zhiguo <yuzg@cn.fujitsu.com>
Keir Fraser [Wed, 10 Feb 2010 13:27:55 +0000 (13:27 +0000)]
Remove hardcoded instances of TIMER_SLOP.
They aren't needed at all, since slop now only delays a timer firing,
rather than allowing it to happen early.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 10 Feb 2010 09:20:56 +0000 (09:20 +0000)]
x86: move trampoline location
A partner of ours is reporting boot failures (Xen not even emitting a
single message) over iSCSI on new (UEFI based) systems. After
pointing at their BIOS initially I finally remembered to take a look
at the memory map a native kernel booted this way see - and voila, the
BIOS reports memory starting at 0x8d000 as reserved. Xen, however,
places about 12k of (trampoline) data at 0x8c000.
For now, move the trampolien down by 4kB to 0x88000. Later we may
choose the location dynamically based on E820 information, if this
proves to be an ongoing problem.
One thing this patch enforces in any case is a single point of
definition for the hard coded location, so that at least adjusting it
won't require more than a single line change in the future.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 10 Feb 2010 09:19:16 +0000 (09:19 +0000)]
tools/remus: fix build in (symlinked) read-only source tree
Modifying source files should generally be avoided; if it is being
done, care should at least be taken to not attempt writes to read-only
files.
While at it, also force the whole ugly construct to fail if any of its
commands fails.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 10 Feb 2010 09:18:43 +0000 (09:18 +0000)]
Fix domain reference leaks
Besides two unlikely/rarely hit ones in x86 code, the main offender
was tmh_client_from_cli_id(), which didn't even have a counterpart
(albeit it had a comment correctly saying that it causes d->refcnt to
get incremented). Unfortunately(?) this required a bit of code
restructuring (as I needed to change the code anyway, I also fixed
a couple os missing bounds checks which would sooner or later be
reported as security vulnerabilities), so I would hope Dan could give
it his blessing before it gets applied.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 10 Feb 2010 09:18:11 +0000 (09:18 +0000)]
x86: MCE fixes
- fill_vmsr_data() leaked a domain reference; since the caller already
obtained one, there's no need to obtain another one here
- intel_UCR_handler() could call put_domain() with a NULL pointer
- mcheck_mca_logout() updated a local data structure that wasn't used
after the update
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Keir Fraser [Wed, 10 Feb 2010 09:09:35 +0000 (09:09 +0000)]
tmem: Disable by default: enable with Xen boot param 'tmem'
This reverts 20758:
4e56f809ddbf and 20655:
3c5b5c4c1d79
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Wed, 10 Feb 2010 09:07:48 +0000 (09:07 +0000)]
xend: Enlarge the memory balloon size for domain creation since shadow
pre-allocation size has changed from 1M to 4M.
Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Keir Fraser [Wed, 10 Feb 2010 09:06:59 +0000 (09:06 +0000)]
xenpm: Fix ia64 build
cpuid_eax() is x86-specific.
Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
Keir Fraser [Mon, 8 Feb 2010 10:18:51 +0000 (10:18 +0000)]
Dump machine check context for fatal machine check
This small patches enable Xen hypervisor to always dump machine check
ontext, previously it will not print anything if fatal MCE happens. It
also add checking for NULL pointer.
It also change the address passing to guest to always use guest
mfn. It should benifit non-translated guest.
Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Keir Fraser [Mon, 8 Feb 2010 10:18:14 +0000 (10:18 +0000)]
Don't scrub broken pages
Don't touch the poison pages when scrub the pages. Consuming poison
page will contaminate the CPU context and may cause system crash.
Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Keir Fraser [Mon, 8 Feb 2010 10:14:48 +0000 (10:14 +0000)]
Some time-handling fixes.
Fixes my domU boot hangs (when using vtsc) due to vtsc_offset less
then local cpu's stime_local_stamp, leading to bogus
vcpu_time_info.tsc_timestamp.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 8 Feb 2010 08:50:03 +0000 (08:50 +0000)]
tools/xenconsole: fix Segmentation fault
Segmentation fault occurs if DOMID isn't specified.
Some check be added to output error message in this situation.
Signed-off-by: Yu Zhiguo <yuzg@cn.fujitsu.com>
Keir Fraser [Mon, 8 Feb 2010 08:49:19 +0000 (08:49 +0000)]
Handle bogus serial ports that appear normal, but don't generate
interrupts e.g. the "remote serial console" on Blades.
Authored-by: Gary Grebus <Gary.Grebus@oracle.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Keir Fraser [Mon, 8 Feb 2010 08:48:40 +0000 (08:48 +0000)]
xenpm: Allow user to enable/disable dbs governor turbo mode.
Signed-off-by: Lu Guanqun <guanqun.lu@intel.com>
Keir Fraser [Mon, 8 Feb 2010 08:43:25 +0000 (08:43 +0000)]
vmx: Don't enable irq for machine check vmexit handling
We should not enable irq for machine check VMExit
In changeset 18658:
824892134573, IRQ is enabled during VMExit except
external interrupt. The exception should apply for machine check also,
because :
a) The mce_logout_lock should be held in irq_disabled context.
b) The machine check event should be handled as quickly as possible,
enable irq will increase the period greatly.
Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
Keir Fraser [Mon, 8 Feb 2010 08:41:51 +0000 (08:41 +0000)]
remus: Only build kernel module if parent kernel has IMQ configured.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>